<extend name="Space/index" />
<block name="main">
<div id="ct" class="ct2 wp cl">
<div class="mn">
<div class="bm">
<div class="bm_h">
<h1 class="mt">留言板</h1>
</div>
<div class="bm_c">
<form id="quickcommentform_33056037" onsubmit=" return false" name="form1" method="post">

<div class="tedt mtn mbn">
<div class="area">
<textarea id="comment_message" name="lytext" rows="5" class="pt"></textarea>
</div>
</div>
<p>
<input name="lyuid" value="<{$lyuid}>" type="hidden">
<input name="lytime" value="<{$lytime}>" type="hidden">
<input name="pid" value="<{$pid}>" type="hidden">
<input name="uname" value="<$uname>" type="hidden">
<input name="blyuid" value="<?php echo $_GET['uid']?>" type="hidden">

<button type="button" onclick="doSubmit()" name="commentsubmit_btn" id="commentsubmit_btn" lyid='0' class="pn"><strong>留言</strong></button>

<button type="button" onclick="doSubmit()" lyid='0' name="commentsubmit_btn1" id="commentsubmit_btn1" class="pn" style="display:none"><strong>回复</strong></button>
<span id="return_qcwall_33056037"></span>
</p>

<script type="text/javascript">
function doSubmit(){
	jQuery.noConflict();
    var pid= 0;
    var btndisplay = jQuery('#commentsubmit_btn').css('display');
    if(btndisplay == 'none'){
        pid = jQuery('#commentsubmit_btn1').attr('lyid');
    }
	var lyMessage=document.getElementById('comment_message').value;
	jQuery.ajax({
        dataType:'json',
        type:'post',
        url:"<{:U('Space/doLiuyan')}>",
        data:{'uname':'<{$uname}>','lytime':'<{$lytime}>','lyuid':'<{$lyuid}>','lytext':lyMessage,'pid':pid, 'blyuid':<?php echo $_GET['uid']?>},
        success:function(data)
        {
            var data= eval(data);
            if(btndisplay == 'none'){
                //回复
                jQuery('.tianjia'+pid).after('<dl id="comment_95469_li" class="bbda cl"><dd class="m avt"><a mid="card_5059" href="http://www.miui.com/space-uid-829729923.html" c="1"><img src="__PUBLIC__/Home/image/space/touxiang/1469853483.jpeg"></a></dd><dt><span class="y xw0"></span><a href="http://www.miui.com/space-uid-829729923.html" id="author_95469">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'+data.uname+'</a><span class="xg1 xw0">&nbsp;'+data.lytime+'</span></dt><dd id="comment_95469">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'+data.lytext+'<a href="javascript:doReplay('+data.lyid+')" style="float:right">回复</a></dd></dl><a name="comment_anchor_94462" class="tianjia'+data.lyid+'"></a>');
                jQuery('#comment_message').attr('value','');           
            }else{
                //留言
                jQuery('#comment_ul').append('<dl id="comment_95469_li" class="bbda cl"><dd class="m avt"><a mid="card_5059" href="http://www.miui.com/space-uid-829729923.html" c="1"><img src="__PUBLIC__/Home/image/space"></a></dd><dt><span class="y xw0"></span><a href="http://www.miui.com/space-uid-829729923.html" id="author_95469">'+data.uname+'</a><span class="xg1 xw0">&nbsp;'+data.lytime+'</span></dt><dd id="comment_95469">'+data.lytext+'<a href="javascript:doReplay('+data.lyid+')" style="float:right">回复</a></dd></dl><a name="comment_anchor_94462" class="tianjia'+data.lyid+'"></a>');
                jQuery('#comment_message').attr('value',''); 
            }
            
        },
        error:function(data)
        {
            
        },
    })
}

</script>
</form>
<div id="div_main_content" class="mtm mbm">
<div id="comment">

<div id="comment_ul" class="xld xlda"><a name="comment_anchor_95469"></a>
<volist name="data" id="vo">	
<dl id="comment_95469_li" class="bbda cl"><dd class="m avt"><a mid="card_5059" href="http://www.miui.com/space-uid-829729923.html" c="1"><img src="__PUBLIC__/Home/image/space" onerror="this.onerror=null;this.src='http://ucenter.miui.com/uc_server16/images/noavatar_small.gif'"></a></dd>
<dt>
<span class="y xw0">

<!--a href="home.php?mod=spacecp&amp;ac=common&amp;op=report&amp;idtype=comment&amp;id=95469&amp;handlekey=reportcommenthk_95469" id="a_report_95469" onclick="showWindow(this.id, this.href, 'get', 0);">举报</a-->
</span>

<a href="http://www.miui.com/space-uid-829729923.html" id="author_95469"><{$vo.username}></a>
<span class="xg1 xw0"><{$vo.lytime}></span>
</dt>

<dd id="comment_95469"><{$vo.lytext}><a href="javascript:doReplay('<{$vo.lyid}>')" style="float:right">回复</a></dd>
</dl><a name="comment_anchor_94462<{$vo.lyid}>" class="tianjia<{$vo.lyid}>"></a>
</volist>
<script type="text/javascript">
 function doReplay(i)
 {
    jQuery('#commentsubmit_btn1').show();
    jQuery('#commentsubmit_btn').hide();
    jQuery('#commentsubmit_btn1').attr('lyid',i);
    jQuery('#comment_message').focus();
 }   
</script>
</div>
</div>
<div class="pgs cl mtm"></div>
</div>
<script type="text/javascript">
var elems = selector('dd[class~=magicflicker]');
for(var i=0; i<elems.length; i++){
magicColor(elems[i]);
}
function succeedhandle_qcwall_37127172(url, msg, values) {
wall_add(values['cid']);
}
</script>

</div>
</div>
</div>
<div class="sd"><div id="pcd" class="bm cl"><div class="bm_c">
<div class="hm">
                    <p>
                        <img src="__PUBLIC__/Home/image/space/touxiang/<{$image}>" width="120">
                    </p>
                    <h2 class="mbn"><a href="<{:U('Space/index')}>" target="_blank"><{$username}></a></h2>
                </div>
                <ul class="xl xl2 cl ul_list">
                    <li class="ul_avt"><a href="<{:U('Space/edithead',array('uid'=>$_SESSION['uid']))}>">编辑头像</a></li>
                    <li class="ul_profile"><a href="<{:U('Space/ziliao',array('uid'=>$_SESSION['uid']))}>">更新资料</a></li>
                </ul>
</div>
</div>
</div>
<script type="text/javascript">
function succeedhandle_followmod(url, msg, values) {
var fObj = $('followmod');
if(values['type'] == 'add') {
fObj.innerHTML = '取消收听';
fObj.href = 'home.php?mod=spacecp&ac=follow&op=del&fuid='+values['fuid'];
} else if(values['type'] == 'del') {
fObj.innerHTML = '收听TA';
fObj.href = 'home.php?mod=spacecp&ac=follow&op=add&hash=cdd35366&fuid='+values['fuid'];
}
}
</script></div                                                      
        
</block>

